package cn.alm.serviceorder.feign;

import cn.alm.serviceorder.dto.WeatherDto;
import cn.alm.serviceorder.feign.fallback.WeatheFeignClientFallback;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

@FeignClient(url = "http://localhost:11000", value = "service-weather", fallback = WeatheFeignClientFallback.class)
public interface WeatherFeignClient {

    @PostMapping("api/weather/get")
    String getWeather(@RequestBody WeatherDto weatherDto, @RequestHeader("x-token") String token);

    @GetMapping("api/weather/test_low_request")
    String testLowRequest();

    @GetMapping("api/weather/req_ex")
    String reqEx();

}
